package com.itheima.mapper;

import com.itheima.domain.Student;
import com.itheima.domain.User;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/*
* 业务层接口
* */
public interface UserMapper {

    //通过账号密码获取用户
    @Select("select * from user where username=#{username} and password=#{password}")
    User login(@Param("username") String username,@Param("password") String password);


    @Select("select * from student")
    List<Student> findAll();
}
